﻿using System;
using System.Data;
using System.Configuration;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Xml;

/// <summary>
/// Summary description for ForumMessage
/// </summary>
public class ForumMessage
{
    private int _messageID;
    private string _title;
    private string _body;

    public String title
    {   
        get
        {
            return _title;
        }
        set
        {
            _title = value;
        }
    }

    public string body
    {
        get
        {
            return _body;
        }
        set
        {
            _body=value;
        }
    }

    public int messageID
    {
        get
        {
            return _messageID;
        }
        set
        {
            _messageID=value;
        }
    }


	public ForumMessage(XmlNode node)
	{
	    _messageID = Convert.ToInt32(node.Attributes["id"].Value);
        _title = node.SelectSingleNode("title").InnerText;
        _body = node.SelectSingleNode("body").InnerText;
	}
    //messageID = int.Parse(node.Attributes["id"].Value);
    //title = node.SelectSingleNode("title").InnerText;
    //body = node.SelectSingleNode("body").InnerText;

}
